home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / newsgrp / group96a.txt / 000190_icon-group-sender _Mon Aug 19 15:11:58 1996.msg < prev    next >
Internet Message Format  |  1996-09-05  |  1KB

  1. Received: by cheltenham.cs.arizona.edu; Tue, 20 Aug 1996 08:07:37 MST
  2. Date: Mon, 19 Aug 1996 15:11:58 -0700
  3. From: kwalker@orville.premenos.com (Ken Walker)
  4. Message-Id: <199608192211.PAA11095@varda.premenos.com>
  5. To: icon-group@cs.arizona.edu, cwfraser@microsoft.com
  6. Subject: Re: evaluating
  7. Mime-Version: 1.0
  8. Content-Type: text/plain; charset=us-ascii
  9. Content-Transfer-Encoding: 7bit
  10. Content-Md5: b9bYLMWJUzCATydTrFLMLA==
  11. Errors-To: icon-group-errors@cs.arizona.edu
  12.  
  13. > From: Chris Fraser <cwfraser@microsoft.com>
  14. > Date: Mon, 19 Aug 1996 10:15:36 -0700
  15. > During the evaluation of, say,
  16. >     every (1 to 1000000)/real(n) ...
  17. > n is converted to floating point once, not one million times, right?
  18.  
  19. In general, evaluation is left to right. real(n) is evaluated after
  20. (1 to 1000000). If n changes between iterations, the semantics of Icon
  21. requires that real(n) be reevaluted. The optimizing compiler does not
  22. do enough analysis to determine if the expression can be evaluated just once
  23. in this case, so it will be evaluated one million times reguardless
  24. of whether you use the interpreter or the compiler.
  25.  
  26. Ken Walker, kwalker@premenos.com
  27. Premenos Coporation, Concord, Ca. 94520
  28.  
  29.